package com.letoken.platform.admin.service;

import com.letoken.platform.pub.req.PageData;
import com.letoken.platform.repo.admin.req.config.*;
import com.letoken.platform.repo.admin.res.config.*;
import com.letoken.platform.repo.admin.res.user.QueryRoleTypeRes;
import com.letoken.platform.repo.common.CommDropDownRes;

import java.util.List;

/**
 * @author letokenlabs
 * @date 2022/11/24$
 */
public interface AdminConfigService {
    void addRechargeConfig(AddRechargeConfigReq req);

    PageData<QueryRechargeConfigRes> queryRechargeConfigList(QueryRechargeConfigReq req);

    void updateRechargeConfig(UpdateRechargeConfigReq req);

    void addExtractConfig(AddExtractConfigReq req);

    void updateExtractConfig(UpdateExtractConfigReq req);

    void deleteExtractConfig(DeleteExtractConfigReq req);

    PageData<QueryExtractConfigRes> queryExtractConfigList(QueryExtractConfigReq req);

    List<QueryRechargeTokenListRes> queryRechargeTokenList();

    List<QueryLevelConfigRes> queryLevelList();


    PageData<QueryQuickswapConfigRes> queryQuickswapList(QueryQuickswapConfigReq req);

    void addQuickswapConfig(AddQuickswapConfigReq req);

    void updateQuickswapConfig(UpdateQuickswapConfigReq req);

    void deleteQuickswapConfig(DeleteQuickswapConfigReq req);

    QueryIssueConfigRes queryIssueList(QueryIssueConfigReq req);

    void updateIssueConfig(UpdateIssueConfigReq req);

    PageData<QueryRewardConfigRes> queryRewardList(QueryRewardConfigReq req);

    QueryCirculationConfigRes queryCirculationList(QueryCirculationConfigReq req);

    void updateCirculationConfig(UpdateCirculationConfigReq req);

    void updateRewardConfig(UpdateRewardConfigReq req);

    PageData<QueryAnnouncementRes> queryAnnouncementList(QueryAnnouncementReq req);

    PageData<QueryAnnouncementRes> queryOneLevelAnnouncementList(QueryAnnouncementReq req);

    List<QueryAnnouncementRes> queryTwoLevelAnnouncementList(Long pid);

    PageData<QueryVersionRes> queryVersionList(QueryVersionReq req);

    void updateVersionConfig(UpdateVersionReq req);

    void addVersionConfig(AddVersionReq req);

    void deleteVersionConfig(DeleteVersionReq req);

    void addAnnouncementConfig(AddAnnouncementReq req);

    void updateAnnouncementConfig(UpdateAnnouncementReq req);

    void deleteAnnouncementConfig(DeleteAnnouncementReq req);

    String queryUserAgreementList();

    void updateUserAgreementConfig(UpdateUserAgreementReq req);

    void ShowAnnouncementConfig(Long id);

    void hideAnnouncementConfig(Long id);

    List<QueryRoleTypeRes> queryRoleType();

    QueryAnnouncementByIdRes queryAnnouncementById(Long id);

    QueryVersionByIdRes queryVersionById(Integer id);

    QueryRechargeConfigByIdRes queryRechargeConfigById(Integer id);

    QueryExtractConfigByIdRes queryExtractConfigById(Integer id);

    List<QueryTokenListRes> queryReTokenList();

    String queryAboutUsList();

    void updateAboutUs(UupdateAboutUsReq req);

    PageData<QueryGuideRes> queryGuideList(QueryGuideReq req);

    void addGuideList(AddGuideReq req);

    void updateGuideList(UpdateGuideReq req);

    void deleteGuideList(Long id);


    QueryRewardConfigRes queryReward();

    void forceUpdateVersionById(Integer id);

    void notForceUpdateVersionById(Integer id);

    /**
     * 查询网络节点配置列表
     * @param req
     * @return
     */
    PageData<QueryChainNodeListRes> queryChainNodeList(QueryChainNodeReq req);

    /**
     * 查询网络类型下拉框
     * @return
     */
    List<CommDropDownRes> queryNetTypeList();

    /**
     * 新增网络节点配置
     * @param req req
     */
    void addChainNode(AddChainNodeReq req);

    /**
     * 修改网络节点配置
     * @param req req
     */
    void updateChainNode(UpdateChainNodeReq req);

    /**
     * 修改网络节点配置
     * @param id id
     * @return return
     */
    QueryChainNodeListRes queryChainNodeById(Integer id);

    /**
     * 根据id启用或禁用网络节点配置
     * @param id id
     * @param flag flag
     * @return return
     */
    String chainNodeIsShow(Integer id, Boolean flag);

    /**
     * 新增网络节点地址配置
     * @param req req
     */
    void addNodeAddressNode(AddChainNodeAddressReq req);

    /**
     * 查询网络节点地址配置列表
     * @param req req
     * @return return
     */
    PageData<QueryNodeAddressListRes> queryNodeAddressList(QueryAddressNodeReq req);

    QueryNodeAddressRes queryNodeAddressById(Integer id);

    void updateChainNodeAddress(UpdateNodeAddressReq req);

    String nodeAddressIsShow(Integer id, Boolean flag);

    QueryAnnouncementByIdRes queryByPidAndLang(QueryPidAndLangReq req);

    void isLockedRechargeConfig(Integer id, Boolean flag);
}
